Page 1 of 1

Micropython port for the CC2640 Smart RF06

Posted: Fri Oct 21, 2016 10:17 am
by saudahmed
Salutations,

This is my first post on this specific forum related to other boards since I first read about Micropython a week ago. For myresearch project I am trying to port Micropython to CC2640 with Smart RF06 development board. This board can be used to evaluate CC2640 as well. CC2640 is a SoC comprised of ARM Cortex-M3 and a Bluetooth Wireless MCU with a Bluetooth low Energy (BLE) stack. It has some limitations. Max CPU frequency is 48Mhz, 128KB of In-System programmable Flash, 8 KB of SRAM Cache and 20 KB of SRAM.
I searched the forum and found out somebody has done similar thing for CC3200. This could be of very great help. Can anybody tell me from where should I start from. What basics I need to cover and should know before porting. I am beginner in this. So any help will be very much appreciated.

Regards
Saud Ahmed

Re: Micropython port for the CC2640 Smart RF06

Posted: Sat Oct 22, 2016 7:06 am
by shaoziyang
128KB flash is not enough for port micropython, it nedd at least 256KB.

Re: Micropython port for the CC2640 Smart RF06

Posted: Sat Oct 22, 2016 7:38 am
by dhylands
Well minimal runs in about 70k so you can still do something but not as fully featured as the pyboard.

Re: Micropython port for the CC2640 Smart RF06

Posted: Sun Oct 23, 2016 2:18 pm
by saudahmed
For final Python port, can anybody guide from where should I start and look into

Re: Micropython port for the CC2640 Smart RF06

Posted: Sun Oct 23, 2016 7:20 pm
by dhylands
The general advice is to bring up minimal, which provides bare-bones MicroPython and puts the REPL on a UART (you'll have to write the UART code for your platform).

Then you can start enabling additional MicroPython features and/or providing additional board support for your platform.

Re: Micropython port for the CC2640 Smart RF06

Posted: Mon Oct 24, 2016 9:06 am
by saudahmed
how can I bring a minimal bare bone Micropython on to my platform. Any guide or similar post related to it.

Re: Micropython port for the CC2640 Smart RF06

Posted: Mon Oct 24, 2016 9:45 pm
by dhylands
minimal will run on a pyboard.

All of the pyboard specific code is wrapped by MICROPY_MIN_USE_STM32_MCU and MICROPY_MIN_USE_CORTEX_CPU defines. So you need to provide functions for your board (with new defines), and also provide an appropriate linker script for your board (the pyboard version of minimal uses stm32f405.ld).