> Madness! There's thousands of people all over the world doing the same
> non-productive work.
No kidding...
That's why a major component of our talk at DEFCON involved the idea that the ARM toolchain on Linux needs to be *seriously* revamped so it doesn't suck. That includes both the programming tools (OpenOCD is a nightmare) and the toolchain integration (per-chip headers, linkscripts, crt.o's, and everything else). Right now it's a total crapshoot whether the chip you select is going to have any kind of sane (and vaguely functional) example somewhere out there, otherwise you have to pry highly non-standard files out of the manuf's crappy IDE and try to shoehorn them into your own project.
Compiling for ARM should work like AVR:
arm-...-gcc -mmcu=stm32f103rb -o program program.c
<EOM>
> Madness! There's thousands of people all over the world doing the same
> non-productive work.
Not entirely non-productive, since I did eventually find a way to make it work. ;-)
And no, OpenOCD, Keil, IAR, Segger, etc are not the answer when you want something to work in a way dramatically different than the established norm....
> On Tue, Aug 21, 2012 at 2:54 AM, Paul Stoffregen <p...@pjrc.com> wrote:
>> The thing I found most difficult about Nuvoton was getting the chip to
>> reboot without connecting the reset line, using only SWDIO and SWDCLK.
>> Nuvoton's flash memory controller has a bit that's supposed to initiate a
>> software reboot. At least in the one chip I've been using, I pretty much
>> came to the conclusion it simply doesn't work. The system control block in
>> the M0 core has a AIRCR register that is supposed to provide a software
>> reset that's vendor neutral for all ARM cores. That also doesn't work on
>> Nuvoton. I tried writing to them both via the debug port MEM-AP and by code
>> running from RAM. I'm pretty sure it's an undocumented silicon bug. I
>> tried the same on another ARM from a different vendor, and AIRCR works fine.
>> Later I found another bit in Nuvton's own system control peripheral, in the
>> IPRSTC1 register, which does actually work. So many hours lost......
>> On 08/20/2012 09:48 PM, Jim Larson wrote:
>>> In my limited experience (smallish - 256K - STM ARMS and 128K Nuvoton),
>>> I've found OpenOCD works well for the STMs and will talk to the Nuvoton:
>>> reset, start, examine registers, set bits, etc. What OpenOCD won't do for
>>> the Nuvoton is program the flash! For that, you have to write the
>>> programming code as Paul said. (It goes in OpenOCD, but you still have to
>>> write it.) I found the Nuvoton documentation to be woefully inadequate as a
>>> guide to programming the flash and gave up on it. The STMs worked just fine
>>> and OpenOCD was a good environment for developing them.
>>> -jim
>>> On 8/20/2012 7:44 PM, David Turnbull wrote:
>>>> It's pretty easy to find tools for SWD and JTAG. e.g. OpenOCD and the
>>>> 1st party tools. All the ARM chips I've looked at have the silicon to
>>>> support this, even Nuvoton. Why are you writing custom bootloaders?
>>>> -david
>>>> On Mon, Aug 20, 2012 at 7:22 PM, Paul Stoffregen<p...@pjrc.com> wrote:
>>>>> For Nuvoton, I've ended up going to the ARM Ltd documentation. It's
>>>>> amazing
>>>>> how much of documentation there is, yet how little of it actually
>>>>> describes
>>>>> how to actually use anything. Everything seems to be just raw
>>>>> documentation
>>>>> for each little module. No examples, no explanations, just raw facts.
>>>>> Unlike AVR where there's a pretty simple ISP programming interface, you
>>>>> pretty much have to build a debug system using ARM's very complex
>>>>> protocols,
>>>>> take control of the processor core, and then to program the flash you
>>>>> need
>>>>> to load and execute in RAM your own code (plus the data you want
>>>>> flashed)
>>>>> which does the work using the chip's in-application flash programming
>>>>> interface.
>>>>> Compared to the convenient hardware interfaces and/or bootloaders that
>>>>> are
>>>>> so common on 8 bit chips, it's a pretty incredible hurdle to building
>>>>> any
>>>>> workable tools. Of course, many of the ARM chips have nice bootloaders
>>>>> in
>>>>> ROM, but not Nuvoton!
>>>> _______________________________________________
>>>> dorkbotpdx-blabber mailing list
>>>> dorkbotpdx-blab...@dorkbot.org
>>>> http://music.columbia.edu/mailman/listinfo/dorkbotpdx-blabber
>>>> -----
>>>> No virus found in this message.
>>>> Checked by AVG - www.avg.com >>>> Version: 2012.0.2197 / Virus Database: 2437/5212 - Release Date: 08/20/12
> And no, OpenOCD, Keil, IAR, Segger, etc are not the answer when you want
> something to work in a way dramatically different than the established
> norm....
Agreed, since I had to build my own complete toolset to do parallel Xmega programming with full isolation... I did manage to make it work with avrdude, though I had to modify it slightly, and it has to feed through my multiplexer daemon.
I'm curious specifically in what way what you're trying to do conflicts with the "standard" approaches? Does it boil down to an architectural flaw in one of the standard tools? Would more factorizable tools help?
_______________________________________________
dorkbotpdx-blabber mailing list
dorkbotpdx-blab...@dorkbot.org
http://music.columbia.edu/mailman/listinfo/dorkbotpdx-blabber
On Mon, Aug 20, 2012 at 7:28 PM, Zach Archer <zkarc...@gmail.com> wrote:
> Suppose you wired the Maple's digital outputs to a DAC
> (digital-to-analog converter). Would that be fast enough to synthesize
> sound at audio rates?
> -- Zach
> zacharcher.com
> On Mon, Aug 20, 2012 at 4:59 PM, Paul Stoffregen <p...@pjrc.com> wrote:
>> Wow, I didn't know Cypress had ARM *and* 20 bit analog.... crazy! Too bad
>> those analog bits aren't at audio bandwidth, but the chips look like they
>> have a lot of nice stuff.
>> I've used the Nuvoton parts. In fact, I have one on a board right here,
>> which you'll probably see in several weeks. Nuvoton's documentation leaves
>> quite a bit to be desired. Maybe the Chinese version is better?
>> As I recall, Don, you built some dev boards with Nuvoton parts quite a long
>> time ago, maybe over a year now? What ever happened with those?
>> On 08/20/2012 04:32 PM, David Turnbull wrote:
>>> The PSoC 5 has a Cortex M3 and does I2S with DMA. I even have code and
>>> circuits for making a 24-bit USB sound card using a PCM3060. My
>>> project uses the $7 48-pin 8051 version of the PSoC, but the code is
>>> the same for the M3.
>>> On Mon, Aug 20, 2012 at 4:26 PM, D Delmar Davis
>>> <art...@suspectdevices.com> wrote:
>>>> Maple native will probably support i2s but its a big and expensive
>>>> processor. The Ret6 had i2s hardware but no native library support and the
>>>> ret6 is not guaranteed to have future libmaple support. Most of the stm32
>>>> peripherals have dma support. For cheap with decent i2s you might look at
>>>> the nuc12x series of chips or as jared boone.
>>>> ....
>>>> On Aug 20, 2012, at 3:46 PM, Paul Stoffregen wrote:
>>>>>> .... I am told that at some time in the future there will be audio.....
>>>>> Does it have an I2S port (not I2C, but I2S) with DMA?
>>>>> _______________________________________________
>>>>> dorkbotpdx-blabber mailing list
>>>>> dorkbotpdx-blab...@dorkbot.org
>>>>> http://music.columbia.edu/mailman/listinfo/dorkbotpdx-blabber
> On 08/21/2012 10:38 AM, Paul Stoffregen wrote:
>> And no, OpenOCD, Keil, IAR, Segger, etc are not the answer when you want
>> something to work in a way dramatically different than the established
>> norm....
> Agreed, since I had to build my own complete toolset to do parallel > Xmega programming with full isolation... I did manage to make it work > with avrdude, though I had to modify it slightly, and it has to feed > through my multiplexer daemon.
> I'm curious specifically in what way what you're trying to do > conflicts with the "standard" approaches?
It's really too early to go into details.
> Does it boil down to an architectural flaw in one of the standard > tools? Would more factorizable tools help?
Basically, no. The existing tools aren't flawed. Well, they aren't flawed, except for missing support for various hardware, bugs, and terrible usability (mostly OpenOCD... Keil & IAR are pretty solid).
They're just fundamentally designed and built around well established paradigms, the standard ways of doing things that are so common that it's hard to imagine any other approach.
The particular STM32 on the Maple Bacon doesn't have onboard DACs, but LeafLabs had a Maple using the RET6 chip (STM32F103RET6 I think) that had onboard DACs. I am in development to expose the pins on that chip and include a MIDI circuit, audio jacks, etc.
> On Mon, Aug 20, 2012 at 7:28 PM, Zach Archer <zkarc...@gmail.com> wrote:
>> Suppose you wired the Maple's digital outputs to a DAC
>> (digital-to-analog converter). Would that be fast enough to synthesize
>> sound at audio rates?
>> -- Zach
>> zacharcher.com
>> On Mon, Aug 20, 2012 at 4:59 PM, Paul Stoffregen <p...@pjrc.com> wrote:
>>> Wow, I didn't know Cypress had ARM *and* 20 bit analog.... crazy! Too bad
>>> those analog bits aren't at audio bandwidth, but the chips look like they
>>> have a lot of nice stuff.
>>> I've used the Nuvoton parts. In fact, I have one on a board right here,
>>> which you'll probably see in several weeks. Nuvoton's documentation leaves
>>> quite a bit to be desired. Maybe the Chinese version is better?
>>> As I recall, Don, you built some dev boards with Nuvoton parts quite a long
>>> time ago, maybe over a year now? What ever happened with those?
>>> On 08/20/2012 04:32 PM, David Turnbull wrote:
>>>> The PSoC 5 has a Cortex M3 and does I2S with DMA. I even have code and
>>>> circuits for making a 24-bit USB sound card using a PCM3060. My
>>>> project uses the $7 48-pin 8051 version of the PSoC, but the code is
>>>> the same for the M3.
>>>> On Mon, Aug 20, 2012 at 4:26 PM, D Delmar Davis
>>>> <art...@suspectdevices.com> wrote:
>>>>> Maple native will probably support i2s but its a big and expensive
>>>>> processor. The Ret6 had i2s hardware but no native library support and the
>>>>> ret6 is not guaranteed to have future libmaple support. Most of the stm32
>>>>> peripherals have dma support. For cheap with decent i2s you might look at
>>>>> the nuc12x series of chips or as jared boone.
>>>>> ....
>>>>> On Aug 20, 2012, at 3:46 PM, Paul Stoffregen wrote:
>>>>>>> .... I am told that at some time in the future there will be audio.....
>>>>>> Does it have an I2S port (not I2C, but I2S) with DMA?
>>>>>> _______________________________________________
>>>>>> dorkbotpdx-blabber mailing list
>>>>>> dorkbotpdx-blab...@dorkbot.org
>>>>>> http://music.columbia.edu/mailman/listinfo/dorkbotpdx-blabber
That's how open source works. (Just look at the history of the Wiring board.) Eventually these things will converge or borrow.
Also, LeafLabs has done a stellar job on libmaple so far. Plus, people are still working on the ARM compiler, as you can see:
https://launchpad.net/gcc-arm-embedded/
Cameron
On Aug 21, 2012, at 10:25 AM, David Turnbull wrote:
> Madness! There's thousands of people all over the world doing the same
> non-productive work.
> -david
> On Tue, Aug 21, 2012 at 2:54 AM, Paul Stoffregen <p...@pjrc.com> wrote:
>> The thing I found most difficult about Nuvoton was getting the chip to
>> reboot without connecting the reset line, using only SWDIO and SWDCLK.
>> Nuvoton's flash memory controller has a bit that's supposed to initiate a
>> software reboot. At least in the one chip I've been using, I pretty much
>> came to the conclusion it simply doesn't work. The system control block in
>> the M0 core has a AIRCR register that is supposed to provide a software
>> reset that's vendor neutral for all ARM cores. That also doesn't work on
>> Nuvoton. I tried writing to them both via the debug port MEM-AP and by code
>> running from RAM. I'm pretty sure it's an undocumented silicon bug. I
>> tried the same on another ARM from a different vendor, and AIRCR works fine.
>> Later I found another bit in Nuvton's own system control peripheral, in the
>> IPRSTC1 register, which does actually work. So many hours lost......
>> On 08/20/2012 09:48 PM, Jim Larson wrote:
>>> In my limited experience (smallish - 256K - STM ARMS and 128K Nuvoton),
>>> I've found OpenOCD works well for the STMs and will talk to the Nuvoton:
>>> reset, start, examine registers, set bits, etc. What OpenOCD won't do for
>>> the Nuvoton is program the flash! For that, you have to write the
>>> programming code as Paul said. (It goes in OpenOCD, but you still have to
>>> write it.) I found the Nuvoton documentation to be woefully inadequate as a
>>> guide to programming the flash and gave up on it. The STMs worked just fine
>>> and OpenOCD was a good environment for developing them.
>>> -jim
>>> On 8/20/2012 7:44 PM, David Turnbull wrote:
>>>> It's pretty easy to find tools for SWD and JTAG. e.g. OpenOCD and the
>>>> 1st party tools. All the ARM chips I've looked at have the silicon to
>>>> support this, even Nuvoton. Why are you writing custom bootloaders?
>>>> -david
>>>> On Mon, Aug 20, 2012 at 7:22 PM, Paul Stoffregen<p...@pjrc.com> wrote:
>>>>> For Nuvoton, I've ended up going to the ARM Ltd documentation. It's
>>>>> amazing
>>>>> how much of documentation there is, yet how little of it actually
>>>>> describes
>>>>> how to actually use anything. Everything seems to be just raw
>>>>> documentation
>>>>> for each little module. No examples, no explanations, just raw facts.
>>>>> Unlike AVR where there's a pretty simple ISP programming interface, you
>>>>> pretty much have to build a debug system using ARM's very complex
>>>>> protocols,
>>>>> take control of the processor core, and then to program the flash you
>>>>> need
>>>>> to load and execute in RAM your own code (plus the data you want
>>>>> flashed)
>>>>> which does the work using the chip's in-application flash programming
>>>>> interface.
>>>>> Compared to the convenient hardware interfaces and/or bootloaders that
>>>>> are
>>>>> so common on 8 bit chips, it's a pretty incredible hurdle to building
>>>>> any
>>>>> workable tools. Of course, many of the ARM chips have nice bootloaders
>>>>> in
>>>>> ROM, but not Nuvoton!
> The particular STM32 on the Maple Bacon doesn't have onboard DACs, but LeafLabs had a Maple using the RET6 chip (STM32F103RET6 I think) that had onboard DACs. I am in development to expose the pins on that chip and include a MIDI circuit, audio jacks, etc.
> Cameron
> On Aug 21, 2012, at 10:51 AM, Zach Archer wrote:
>> On Mon, Aug 20, 2012 at 7:28 PM, Zach Archer <zkarc...@gmail.com> wrote:
>>> Suppose you wired the Maple's digital outputs to a DAC
>>> (digital-to-analog converter). Would that be fast enough to synthesize
>>> sound at audio rates?
>>> -- Zach
>>> zacharcher.com
>>> On Mon, Aug 20, 2012 at 4:59 PM, Paul Stoffregen <p...@pjrc.com> wrote:
>>>> Wow, I didn't know Cypress had ARM *and* 20 bit analog.... crazy! Too bad
>>>> those analog bits aren't at audio bandwidth, but the chips look like they
>>>> have a lot of nice stuff.
>>>> I've used the Nuvoton parts. In fact, I have one on a board right here,
>>>> which you'll probably see in several weeks. Nuvoton's documentation leaves
>>>> quite a bit to be desired. Maybe the Chinese version is better?
>>>> As I recall, Don, you built some dev boards with Nuvoton parts quite a long
>>>> time ago, maybe over a year now? What ever happened with those?
>>>> On 08/20/2012 04:32 PM, David Turnbull wrote:
>>>>> The PSoC 5 has a Cortex M3 and does I2S with DMA. I even have code and
>>>>> circuits for making a 24-bit USB sound card using a PCM3060. My
>>>>> project uses the $7 48-pin 8051 version of the PSoC, but the code is
>>>>> the same for the M3.
>>>>> On Mon, Aug 20, 2012 at 4:26 PM, D Delmar Davis
>>>>> <art...@suspectdevices.com> wrote:
>>>>>> Maple native will probably support i2s but its a big and expensive
>>>>>> processor. The Ret6 had i2s hardware but no native library support and the
>>>>>> ret6 is not guaranteed to have future libmaple support. Most of the stm32
>>>>>> peripherals have dma support. For cheap with decent i2s you might look at
>>>>>> the nuc12x series of chips or as jared boone.
>>>>>> ....
>>>>>> On Aug 20, 2012, at 3:46 PM, Paul Stoffregen wrote:
>>>>>>>> .... I am told that at some time in the future there will be audio.....
>>>>>>> Does it have an I2S port (not I2C, but I2S) with DMA?
>>>>>>> _______________________________________________
>>>>>>> dorkbotpdx-blabber mailing list
>>>>>>> dorkbotpdx-blab...@dorkbot.org
>>>>>>> http://music.columbia.edu/mailman/listinfo/dorkbotpdx-blabber
> On Aug 21, 2012, at 1:04 PM, Cameron Adamez wrote:
>> The particular STM32 on the Maple Bacon doesn't have onboard DACs, but LeafLabs had a Maple using the RET6 chip (STM32F103RET6 I think) that had onboard DACs. I am in development to expose the pins on that chip and include a MIDI circuit, audio jacks, etc.
>> Cameron
>> On Aug 21, 2012, at 10:51 AM, Zach Archer wrote:
>>> On Mon, Aug 20, 2012 at 7:28 PM, Zach Archer <zkarc...@gmail.com> wrote:
>>>> Suppose you wired the Maple's digital outputs to a DAC
>>>> (digital-to-analog converter). Would that be fast enough to synthesize
>>>> sound at audio rates?
>>>> -- Zach
>>>> zacharcher.com
>>>> On Mon, Aug 20, 2012 at 4:59 PM, Paul Stoffregen <p...@pjrc.com> wrote:
>>>>> Wow, I didn't know Cypress had ARM *and* 20 bit analog.... crazy! Too bad
>>>>> those analog bits aren't at audio bandwidth, but the chips look like they
>>>>> have a lot of nice stuff.
>>>>> I've used the Nuvoton parts. In fact, I have one on a board right here,
>>>>> which you'll probably see in several weeks. Nuvoton's documentation leaves
>>>>> quite a bit to be desired. Maybe the Chinese version is better?
>>>>> As I recall, Don, you built some dev boards with Nuvoton parts quite a long
>>>>> time ago, maybe over a year now? What ever happened with those?
>>>>> On 08/20/2012 04:32 PM, David Turnbull wrote:
>>>>>> The PSoC 5 has a Cortex M3 and does I2S with DMA. I even have code and
>>>>>> circuits for making a 24-bit USB sound card using a PCM3060. My
>>>>>> project uses the $7 48-pin 8051 version of the PSoC, but the code is
>>>>>> the same for the M3.
>>>>>> On Mon, Aug 20, 2012 at 4:26 PM, D Delmar Davis
>>>>>> <art...@suspectdevices.com> wrote:
>>>>>>> Maple native will probably support i2s but its a big and expensive
>>>>>>> processor. The Ret6 had i2s hardware but no native library support and the
>>>>>>> ret6 is not guaranteed to have future libmaple support. Most of the stm32
>>>>>>> peripherals have dma support. For cheap with decent i2s you might look at
>>>>>>> the nuc12x series of chips or as jared boone.
>>>>>>> ....
>>>>>>> On Aug 20, 2012, at 3:46 PM, Paul Stoffregen wrote:
>>>>>>>>> .... I am told that at some time in the future there will be audio.....
>>>>>>>> Does it have an I2S port (not I2C, but I2S) with DMA?
>>>>>>>> _______________________________________________
>>>>>>>> dorkbotpdx-blabber mailing list
>>>>>>>> dorkbotpdx-blab...@dorkbot.org
>>>>>>>> http://music.columbia.edu/mailman/listinfo/dorkbotpdx-blabber