How close is the Swordfish 24F compiler?
Moderators: David Barker, Jerry Messina
Much as I hate to move to C, it looks like it may be time to take the plunge. I would rather stay with SF as it is much nicer to use, but like dmtulsa, I cannot wait any longer.
I have also been looking at NXP LPC11xx parts and they look really nice. A 32-bit part that is cheaper than 8-bit PIC devices (as low as $0.65/10,000 for a 8/2kB part). Some basic specs:
I have also been looking at NXP LPC11xx parts and they look really nice. A 32-bit part that is cheaper than 8-bit PIC devices (as low as $0.65/10,000 for a 8/2kB part). Some basic specs:
The software dev tools are C based only but come free with the purchase of the $30 LPC1114 LPCXpresso board. With this move, I will also use MPLAB and C18 (and C30) and possibly abandon BASIC altogether.# ARM Cortex-M0 processor, running at frequencies of up to 50 MHz
# ARM Cortex-M0 built-in Nested Vectored Interrupt Controller (NVIC)
# 32 kB (LPC1114), 24 kB (LPC1113), 16 kB (LPC1112), or 8 kB (LPC1111) on-chip flash programming memory
# 8 kB, 4 kB, or 2 kB SRAM
# In-System Programming (ISP) and In-Application Programming (IAP) via on-chip bootloader software
# UART with fractional baud rate generation, internal FIFO, and RS-485 support
# Two SPI controllers with SSP features and with FIFO and multi-protocol capabilities (second SPI on LQFP48 and PLCC44 packages only)
# I2C-bus interface supporting full I2C-bus specification and Fast-mode Plus with a data rate of 1 Mbit/s with multiple address recognition and monitor mode
# Up to 42 General Purpose I/O (GPIO) pins with configurable pull-up/pull-down resistors
# Four general purpose 16/32-bit timers/counters with a total of four capture inputs and 13 match/PWM outputs
# Programmable WatchDog Timer (WDT)
# System tick timer
# Serial Wire Debug
# High-current output driver (20 mA) on one pin
# High-current sink drivers (20 mA) on two I2C-bus pins in Fast-mode Plus
# Integrated PMU (Power Management Unit) to minimize power consumption during Sleep, Deep-sleep, and Deep power-down modes
# Three reduced power modes: Sleep, Deep-sleep, and Deep power-down
# Single 3.3 V power supply (1.8 V to 3.6 V)
# 10-bit ADC with input multiplexing among 8 pins
# GPIO pins can be used as edge and level sensitive interrupt sources
# Clock output function with divider that can reflect the system oscillator clock, IRC clock, CPU clock, and the Watchdog clock
# Processor wake-up from Deep-sleep mode via a dedicated start logic using up to 13 of the functional pins
# Brownout detect with four separate thresholds for interrupt and one threshold for forced reset
# Power-On Reset (POR)
# Crystal oscillator with an operating range of 1 MHz to 25 MHz
# 12 MHz internal RC oscillator trimmed to 1 % accuracy that can optionally be used as a system clock
# PLL allows CPU operation up to the maximum CPU rate without the need for a high-frequency crystal. May be run from the main oscillator, the internal RC oscillator, or the watchdog oscillator.
As much as I like the ease of BASIC, I've switched to the C30 compiler for 24 series development. It's been a slow start but I'm getting the hang of it. It's not that C is all that tricky; it still uses the same programming concepts as most other languages. The hard part is learning a new IDE, a new PIC series and C all at the same time! The documentation seems somewhat fragmented and not newbie friendly. Since the IDE is designed for use with many compilers, it's been hard to find good information that steps beginners through C projects. Also, the C libraries seem scattered throughout the installation directories. But the good news is that the compiler is free and actively supported by Microchip.
It wasn't too bad for me. The LPC1114 (32kB FLASH, 8kB RAM) board arrived today and I got the blinky going in about 10 minutes. I did play with the IDE and C compiler for a couple of hours while waiting for the hardware to arrive.
Now on to putting a couple of 2x10 headers on the LPC board to hook it up to the EasyPIC4 board with IDC cables so I can use its peripherals (multiple LEDs/switches, LCD, GLCD, 7-segment LED, RS232, etc.) - just like what was done when working with the PIC24/dsPIC33.
Now on to putting a couple of 2x10 headers on the LPC board to hook it up to the EasyPIC4 board with IDC cables so I can use its peripherals (multiple LEDs/switches, LCD, GLCD, 7-segment LED, RS232, etc.) - just like what was done when working with the PIC24/dsPIC33.
Cortex-M0 or M3 chips are really very nice and very competitive in price comparing to low 8 bit chips. But I don't think that there would be a any basic compiler for them, as all ARM core is professionnal, and most professionnal users will never go back to basic (for historical reasons). ALL libs for these chips are written in "C", and thus I dont see any basic compiler to change that.rmteo wrote:Much as I hate to move to C, it looks like it may be time to take the plunge. I would rather stay with SF as it is much nicer to use, but like dmtulsa, I cannot wait any longer.
Basic has been pushed a lot by the huge number of bobbists working on PIC or AVR chips. These chips are and will still continue to be used by bobbists because ARM based chips (including cortex core one) does not exists in DIP packages. The only ARM based manufacturer that made DIL package (in SMT if I remmeber) was Luminary (now bought by TI) in 28 Pin package.
Sinc this huge ammount of "Basic" potential users cannot play with these chips, I think ARM based chips will still continue to be professionnal reserved chips.
Regards
I also am moving to C.Much as I hate to move to C, it looks like it may be time to take the plunge. I would rather stay with SF as it is much nicer to use, but like dmtulsa, I cannot wait any longer.
The ever expanding Microchip libraries especially for connectivity such as
Ethernet, USB, Can, Wifi and ZigBee are a major draw.
To convert these to C it is almost easier to learn C.
Norm
Well after working with the LPC111x tool chain for about 2 weeks, I have good news and bad news.
First, the good news. The LPC111x hardware is really nice with very powerful and flexible features/peripherals. You basically get PIC32 performance at PIC16 prices - or less. The software is not as easy to use as SF (after all it is C) but at least the IDE with built-in debugger is nice - and it's free.
Now the bad news. Having made the move to C with LPC, I thought I would standardize on C for the PIC. The MPLAB IDE pales in comparison to the LPC IDE and the C18 (and C30) compiler does not have anywhere near the useful modules/drivers that come with SF. Looks like I may have to stay with SF for the time being for the PIC parts - or drop PIC's altogether.
First, the good news. The LPC111x hardware is really nice with very powerful and flexible features/peripherals. You basically get PIC32 performance at PIC16 prices - or less. The software is not as easy to use as SF (after all it is C) but at least the IDE with built-in debugger is nice - and it's free.
Now the bad news. Having made the move to C with LPC, I thought I would standardize on C for the PIC. The MPLAB IDE pales in comparison to the LPC IDE and the C18 (and C30) compiler does not have anywhere near the useful modules/drivers that come with SF. Looks like I may have to stay with SF for the time being for the PIC parts - or drop PIC's altogether.
Looks nice.
Well, I guess that's one of the SF advantages.
I assume the idea was an 'Open' approach to allow contributors to produce nice modules.
And many excellent ones are available.
Sadly, SF hasn't taken off as I would have expected - I don't know why not.
(I'm basing that on Forum numbers. I'm so pleased that this Forum isn't so cliquey as Proton.)
Good price, great principle, great product.
... but diminishing support and probably no more upgrades. Pity.
I guess now the fledgling is older it has simply been allowed to 'fly free'.
Well, I guess that's one of the SF advantages.
I assume the idea was an 'Open' approach to allow contributors to produce nice modules.
And many excellent ones are available.
Sadly, SF hasn't taken off as I would have expected - I don't know why not.
(I'm basing that on Forum numbers. I'm so pleased that this Forum isn't so cliquey as Proton.)
Good price, great principle, great product.
... but diminishing support and probably no more upgrades. Pity.
I guess now the fledgling is older it has simply been allowed to 'fly free'.
I saw a check box allowing an external text editor in MPLAB IDE.The MPLAB IDE pales in comparison to the LPC IDE
You could possibly use your LPC IDE if you choose although not all of the
features would work with PIC.
I wonder if their are other external editors which would fully support
MPLAB C18 etc?
Norm
It is not just the editor (or IDE). A lot of the new ARM hardware (such as the abovementioned LPC111x) have a much nicer architecture and far more powerful and flexible peripherals. ST has also announced several new Cortex M3 based devices that start at under $1.
Now what would be really nice is a BASIC compiler similar to SF for the ARM cores. However, we have waited almost a year and half for the PIC24 version. I believe though, that a BASIC for ARM is something that may soon happen from another source. Keeping my fingers crossed.
Now what would be really nice is a BASIC compiler similar to SF for the ARM cores. However, we have waited almost a year and half for the PIC24 version. I believe though, that a BASIC for ARM is something that may soon happen from another source. Keeping my fingers crossed.
I found two companies working on a Basic compiler for Arm both due within a year (2007).a BASIC for ARM is something that may soon happen from another source
I believe they are still in progress. No small accomplishment.
Having just started in MPLAB C18 I am having difficulty finding C code examples for C18.
Norm
Thanks for the info. I am aware of these 2:
http://www.coridiumcorp.com/Programming3.php
http://www.hbbrbasic.com/documentation/ ... v2000.html
http://www.coridiumcorp.com/Programming3.php
http://www.hbbrbasic.com/documentation/ ... v2000.html
Thanks for the info. I am aware of these 2:
http://www.coridiumcorp.com/Programming3.php
http://www.hbbrbasic.com/documentation/ ... v2000.html
Coridium is an interpreter not compiled code (slower).
Coridium is a stamp ($$each) not sure about HBBR.
MikroElectonica and Bascom are both slowly working on Arm Basic.
Proton is working on a PIC24 basic version. No release date.
2 books for Basic have been started however not heard from for a while.
Two of four new IDE's for Basic are still in progress and near complete.
Norm