Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

analog_loop tests update for STM32 #3024

Merged
merged 2 commits into from
Oct 27, 2016
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 18 additions & 6 deletions features/unsupported/tests/mbed/analog/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ AnalogOut out(PTE30);
AnalogIn in(A0);
AnalogOut out(D12); //D12 is P0_12, the DAC output pin

// no pin to access DAC on these targets:
//TARGET_DISCO_F746NG
// No DAC on these targets:
//TARGET_NUCLEO_F030R8
//TARGET_NUCLEO_F070RB
Expand All @@ -40,32 +42,42 @@ AnalogOut out(D12); //D12 is P0_12, the DAC output pin
defined(TARGET_NUCLEO_F303RE) || \
defined(TARGET_NUCLEO_F334R8) || \
defined(TARGET_NUCLEO_F446RE) || \
defined(TARGET_NUCLEO_F446ZE) || \
defined(TARGET_NUCLEO_L053R8) || \
defined(TARGET_NUCLEO_L073RZ) || \
defined(TARGET_NUCLEO_L476RG) || \
defined(TARGET_NUCLEO_L152RE)
AnalogIn in(A0);
AnalogOut out(A2);

#elif defined(TARGET_NUCLEO_F746ZG)
#elif defined(TARGET_NUCLEO_F303K8)
AnalogIn in(A0);
AnalogOut out(PA_4);
AnalogOut out(A3);

#elif defined(TARGET_NUCLEO_F207ZG)
#elif defined(TARGET_NUCLEO_F207ZG) || \
defined(TARGET_NUCLEO_F746ZG) || \
defined(TARGET_NUCLEO_F303ZE) || \
defined(TARGET_NUCLEO_F410RB) || \
defined(TARGET_NUCLEO_F446ZE) || \
defined(TARGET_NUCLEO_F429ZI)
AnalogIn in(A0);
AnalogOut out(D13);

#elif defined(TARGET_ARCH_MAX)
AnalogIn in(PA_0);
AnalogOut out(PA_4);

#elif defined(TARGET_DISCO_L053C8) || \
defined(TARGET_DISCO_F334C8)
AnalogIn in(PA_1);
AnalogOut out(PA_4);

#elif defined(TARGET_DISCO_F407VG) || \
defined(TARGET_DISCO_F469NI)
AnalogIn in(PC_5);
AnalogOut out(PA_4);

#elif defined(TARGET_NUCLEO_F303ZE)
AnalogIn in(PC_5);
#elif defined(TARGET_DISCO_L476VG)
AnalogIn in(PA_0);
AnalogOut out(PA_5);

#elif defined(TARGET_DISCO_F429ZI)
Expand Down
8 changes: 2 additions & 6 deletions tools/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,8 @@

* analog_loop (AnalogIn, AnalogOut):
* Arduino headers: (A0 <-> A5)
* NUCLEO64: (A0 <-> A2)
* NUCLEO144: (A0 <-> D13)
* LPC1549: (A0 <-> D12)
* LPC1*: (p17 <-> p18 )
* KL25Z: (PTE30 <-> PTC2)
Expand Down Expand Up @@ -187,12 +189,6 @@
"dependencies": [MBED_LIBRARIES, TEST_MBED_LIB],
"automated": True,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm thinking we probably don't want to remove the non-ST boards from this list, as the other boards still require some customization of the pins. Would you mind adding the non-ST boards back to this list?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, I can...
but as there is a check if analog in and out are supported or not in the test,
and test can not be executed while "peripherals" parameter is not set,
I ddidn't see any risk to remove the MCU list

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its not so much that they wouldn't have analog in or out supported, its that the pin names used for the analog loop are only defined for the targets in the mcu list. It would lead to a build error.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

mcu list is back :-)

"peripherals": ["analog_loop"],
"mcu": ["LPC1768", "LPC2368", "LPC2460", "KL25Z", "K64F", "K66F", "K22F", "LPC4088", "LPC1549",
"NUCLEO_F072RB", "NUCLEO_F091RC", "NUCLEO_F302R8", "NUCLEO_F303K8", "NUCLEO_F303RE", "NUCLEO_F207ZG",
"NUCLEO_F334R8", "NUCLEO_F303ZE", "NUCLEO_L053R8", "NUCLEO_L073RZ", "NUCLEO_L152RE",
"NUCLEO_F410RB", "NUCLEO_F411RE", "NUCLEO_F446RE", "NUCLEO_F446ZE",
"DISCO_F407VG", "DISCO_F746NG", "NUCLEO_F746ZG",
"ARCH_MAX", "MAX32600MBED", "MOTE_L152RC", "B96B_F446VE"]
},
{
"id": "MBED_A9", "description": "Serial Echo at 115200",
Expand Down