- Silicon Labs Community
- Welcome and Announcements
- Silicon Labs Knowledge Base
- 8-bit MCU
- 32-bit MCU
- Bluetooth / Wi-Fi
- Other Products Category
- Optical/RH/Temp Sensor
- Other Products
- Hardware and Software Tools
- Simplicity Studio and Software
- General Discussions and Suggestions
- Chinese Forum
- Software Libraries
- Development Kits
- Reference Designs
- Third Party Tools
- White Papers
- Official Blog of Silicon Labs
- Chinese Blog
03-19-2017 10:08 PM
I tried to import HaContactSensorSoc to EFR32MG Kit but I get the following build error. How can I define GPIO_SENSOR_PIN correctly and make it work?
#error "No definition for GPIO_SENSOR_PIN found. Select an pin for this plugin and define it to something like 6"
Fatal error detected, aborting.
Building file: C:/SiliconLabs/SimplicityStudio/v4/developer/sdks/
make: *** [gpio-sensor/EFR32/gpio-sensor.o] Error 2
make: *** Waiting for unfinished jobs....
Solved! Go to Solution.
03-20-2017 12:52 AM
Upated: After adding GPIO_SENSOR_PORT and GPIO_SENSOR_PIN define into gpio-sensor.c, I can solve the build error. However, I end up with the following link error. How can I solve it?
Invoking: IAR Linker for ARM
ilinkarm ./tamper-switch/EFR32/tamper-switch.o ./simple-main/simple-main.o ./sim-eeprom1/EFR32/sim-eeprom.o ./silabs-device-ui/silabs-device-ui.o ./security-sensor/security-sensor.o ./reporting/reporting-cli.o ./reporting/reporting.o ./poll-control-server/poll-control-server.o ./ota-storage-simple-eeprom/ota-storage-eeprom-pag
IAR ELF Linker V126.96.36.19947/W32 for ARM
Copyright 2007-2016 IAR Systems AB.
Error[Lp011]: section placement failed
unable to complete "place at" directives with a total estimated minimum size of 0x3c1a bytes in <[0x20000000-0x20002fef]> (total space 0x2ff0).
Error[Lp015]: section placement failure: overcommitted content in [0x20000000-0x20002fef]
168 926 bytes of readonly code memory
528 bytes of readwrite code memory
49 436 bytes of readonly data memory
23 081 bytes of readwrite data memory (+ 156 absolute)
Link time: 0.87 (CPU) 1.11 (elapsed)
make: *** [HaContactSensorSoc.out] Error 2
03-21-2017 08:32 AM
That error means that your program is too big to fit in the flash on the device. It looks like you're 3249 bytes over. The easiest way to save some flash is to disable debug prints or CLI commands that you don't need. You can do this on the "Printing and CLI" tab in Simplicity Studio.
03-21-2017 10:22 AM
I realized that the issue is RAM, not flash. The problem is the configuration got corrupted when switching from em358x to efr32. I've filed a bug on this. In the mean time, the workaround is:
go to the HAL configuration tab
change the selected architecture to em3587
change ram retention to all
change the selected architecture back to the efr32 you have
change the board header back to your board