DISTORTEC / distortos

object-oriented C++ RTOS for microcontrollers
https://distortos.org/
Mozilla Public License 2.0
430 stars 66 forks source link

Modify generateBoard.py to work in both Python 2 and 3 #30

Closed FreddieChopin closed 7 years ago

FreddieChopin commented 7 years ago

Hi @CezaryGapinski ! Could you check this branch? It works here for both versions of Python, but I have the luxury of having the most recent versions possible (3.6.0 and 2.7.13), so its possible that I accidentally broke something for an older version (;

Thanks in advance!

CezaryGapinski commented 7 years ago

Hi @FreddieChopin!

$ python -V Python 2.6.9 ./scripts/generateBoard.py -c source/board/STM32/STM32F0/NUCLEO-F091RC/NUCLEO-F091RC.json -o source/board/STM32/STM32F0/ ./scripts/generateBoard.py -c source/board/STM32/STM32F1/NUCLEO-F103RB/NUCLEO-F103RB.json ./scripts/generateBoard.py -c source/board/STM32/STM32F4/32F429IDISCOVERY/32F429IDISCOVERY.json ./scripts/generateBoard.py -c source/board/STM32/STM32F4/NUCLEO-F401RE/NUCLEO-F401RE.json ./scripts/generateBoard.py -c source/board/STM32/STM32F4/NUCLEO-F429ZI/NUCLEO-F429ZI.json ./scripts/generateBoard.py -c source/board/STM32/STM32F4/STM32F4DISCOVERY/STM32F4DISCOVERY.json ./scripts/generateBoard.py -c source/board/STM32/STM32F7/32F746GDISCOVERY/32F746GDISCOVERY.json

It works for me on 2.6.9 version (Python 2.6.9 final was released on October 29, 2013). I think there is no need to check this on older version?

FreddieChopin commented 7 years ago

It works for me on 2.6.9 version (Python 2.6.9 final was released on October 29, 2013). I think there is no need to check this on older version?

Yes, probably "old enough" for practical purposes (; Thanks for the review!