z80 vs Python [英] z80 vs Python

查看:64
本文介绍了z80 vs Python的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好!


我有一个想法,为z80实现Python解释器作为支持附加硬件的通用灵活语言(如脚本)。

最简单的方法是什么?

我当然想到C(Zilog对自己的产品有很好的支持......)。

我在等待意见。


最好的问候

Janusz U.

解决方案

>我有一个想法,实现z80的Python解释器作为

通用灵活的语言(如脚本),以支持附加的硬件。
这是最简单的方法吗?我当然想到C(Zilog对自己的产品有很好的支持......)。




我不推荐这个。标准的Python解释器非常庞大(动态链接大于700K),更不用说标准库了。看到

因为Z80只有64K的地址空间,我没有看到完整的实现,因为

可能。


什么你/可能/做的是实现一个(非常)小的Python子集;

即省略生成器,新式类,列表推导,能力

来覆盖内置类型,函数和运算符,以及大多数

标准库,那么你/可能/能够在该地址中使用Pythonic

语法的语言空间。


另一个问题是速度。 Z80虽然它们的速度超过了b
,但仍然只能以10MHz的速度运行。你可能会更好地为一个Python式语言编写Z80编译器
- 这样可以节省速度和内存的价值。


如果你可以选择不同的芯片,那就选择StrongARM这样的东西。

这些具有Python所需的功能和地址空间。另外,它之前已经完成了(b)b(在现代PDA上运行得非常漂亮)。


如果你坚持使用Z80,你已经在你之前获得相当大的挑战

你好运 - 祝你好运!如果你成功了,你肯定会让黑客们玩游戏

男孩,TI-83和TRS-80到处都是神志不清的快乐。


>我不推荐这个。标准的Python解释器非常重要

(> 700K动态链接),更不用说标准库了。看到
因为Z80只有64K的地址空间,我没有看到完整的实现,因为
可能。


我知道。对不起,我没精确。我完全想到了eZ80F91 - 它是基于Z80的b $ b,但是更多的扩展......我将从该处理器的模块开始(和

deviloper kit) 。它将成为Python中用于测试软件的独立平台。

你/可能/做的是实现一个(非常)小的Python子集;
即省略生成器,新式类,列表推导,覆盖内置类型,函数和操作符的能力,以及大部分标准库,那么你/可能/能够在该地址空间中使用Pythonic
语法。


我想用自己的Python扩展语言 - 例如。控制GPIO

eZ80,阅读

另一个问题是速度。 Z80虽然在过去几年里速度更快,但仍然只能以10MHz的速度运行。您可能会更好地为Python语言编写Z80编译器 - 这样可以节省速度和内存。


速度50MHz(或F92中的20MHz,F93 ...)

如果你可以选择不同的芯片,那就选择StrongARM这样的东西吧。这些具有Python所需的功能和地址空间。此外,它之前已经完成(Python在现代PDA上运行得非常漂亮)。


我刚买了eZ80的开发工具包,所以我的方式有限。我会很高兴在eZ80平台上运行Python。


thx

Janusz U.

如果你坚持使用Z80,那么你面临着相当大的挑战 - 祝你好运!祝你好运!如果你成功了,你肯定会让游戏的男孩,TI-83和TRS-80的黑客到处疯狂地开心。



< blockquote>就个人而言,如果我有时间,我会尝试将python移植到gumstix

板:

http://www.gumstix.com/


这可能不会太难但是,它仍然很有趣,它可以在这块小板上得到它。 :)


" Janusz U." <无***** @ poczta.onet.pl>在消息新闻中写道:< cb ********** @ atlantis.news.tpi.pl> ...

我不会''推荐这个。标准的Python解释器非常重要(> 700K动态链接),更不用说标准库了。看到
因为Z80只有64K的地址空间,我没有看到完整的实现可能。



我知道。对不起,我没精确。我完全想到了eZ80F91 - 它是基于Z80的,但更多的扩展...我将从该处理器的模块(和
deviloper工具包)开始。它将是Python中测试软件的独立平台。

你/可以/做什么来实现一个(非常)小的Python子集;
即省略生成器,新式类,列表推导,覆盖内置类型,函数和操作符的能力,以及大部分标准库,那么你/可能/能够在该地址空间中使用Pythonic
语法编写语言。



我认为通过Python自己的库扩展语言 - 例如。控制eZ80的GPIO,阅读


另一个问题是速度。 Z80虽然在过去几年里速度更快,但仍然只能以10MHz的速度运行。你可能会更好地为Python式语言编写Z80编译器 - 这样可以节省速度和内存。



速度50MHz(或20MHz)在F92,F93 ...)


如果你可以选择一个不同的芯片,那就选择像StrongARM这样的东西。
它们有电源和地址空间Python所必需的。此外,之前已经完成了(Python在现代PDA上运行得非常漂亮)。



我刚刚购买了eZ80的开发工具包,所以我的方式有限。我很高兴在eZ80平台上运行Python。

thx
Janusz U.

如果你坚持使用但是,Z80,你有一个相当大的挑战,祝你好运!祝你好运!如果你成功了,你肯定会让游戏的男孩,TI-83和TRS-80的黑客在任何地方都非常高兴。



Hello!

I have an idea that implements the Python interpreter for z80 as an
universal flexible language (like scripts) to support attached hardware.
What would it be shortest way to do it?
I think of course about C (Zilog has good support of own products...).
I''m waiting for the opinion.

The best regards
Janusz U.

解决方案

> I have an idea that implements the Python interpreter for z80 as an

universal flexible language (like scripts) to support attached hardware.
What would it be shortest way to do it?
I think of course about C (Zilog has good support of own products...).



I wouldn''t recommend this. The standard Python interpreter is quite hefty
(>700K dynamically linked), not to mention the standard libraries. Seeing
as Z80 has only 64K address space, I don''t see a full implementation as
possible.

What you /could/ do would be to implement a (very) small subset of Python;
i.e. leave out generators, new-style class, list comprehensions, ability
to override built-in types, functions, and operators, and most of the
standard library, then you /might/ be able to fit a language with Pythonic
syntax in that address space.

Another issue would be speed. Z80s, though they''ve gotten faster over the
years, still only run at speeds on the order of 10MHz. You might be better
off writing a Z80 compiler for a Python-esque language -- this would save
both speed and memory.

If you can pick a different chip, go with something like a StrongARM.
These have the power and address space necessary for Python. Plus, it''s
been done before (Python runs beautifully on modern PDAs).

If you stick with the Z80 though, you''ve got quite a challenge ahead of
you - good luck! If you succeed, you''ll be sure to make hackers of Game
Boys, TI-83s, and TRS-80s everywhere deliriously happy.


> I wouldn''t recommend this. The standard Python interpreter is quite hefty

(>700K dynamically linked), not to mention the standard libraries. Seeing
as Z80 has only 64K address space, I don''t see a full implementation as
possible.
I know. Sorry, I didn''t precise. I thought exactly about eZ80F91 - it''s
based on Z80 but much more expanded... I will start on the module (and
deviloper kit) for that procesor. It would be independent platform for
tests software in the Python.
What you /could/ do would be to implement a (very) small subset of Python;
i.e. leave out generators, new-style class, list comprehensions, ability
to override built-in types, functions, and operators, and most of the
standard library, then you /might/ be able to fit a language with Pythonic
syntax in that address space.
I think to expand language by own library for Python - eg. control GPIO of
eZ80, read

Another issue would be speed. Z80s, though they''ve gotten faster over the
years, still only run at speeds on the order of 10MHz. You might be better
off writing a Z80 compiler for a Python-esque language -- this would save
both speed and memory.
speed 50MHz (or 20MHz in F92, F93...)

If you can pick a different chip, go with something like a StrongARM.
These have the power and address space necessary for Python. Plus, it''s
been done before (Python runs beautifully on modern PDAs).
I have just bought the developer kit for eZ80 so I have limited way. I''d be
happy to run Python on eZ80 platform.

thx
Janusz U.
If you stick with the Z80 though, you''ve got quite a challenge ahead of
you - good luck! If you succeed, you''ll be sure to make hackers of Game
Boys, TI-83s, and TRS-80s everywhere deliriously happy.



Personally, if I had the time, I''d try porting python to a gumstix
board:

http://www.gumstix.com/

It probably wouldn''t be too hard, but still, it''d be fun to get it
onto that tiny board. :)


"Janusz U." <no*****@poczta.onet.pl> wrote in message news:<cb**********@atlantis.news.tpi.pl>...

I wouldn''t recommend this. The standard Python interpreter is quite hefty
(>700K dynamically linked), not to mention the standard libraries. Seeing
as Z80 has only 64K address space, I don''t see a full implementation as
possible.



I know. Sorry, I didn''t precise. I thought exactly about eZ80F91 - it''s
based on Z80 but much more expanded... I will start on the module (and
deviloper kit) for that procesor. It would be independent platform for
tests software in the Python.

What you /could/ do would be to implement a (very) small subset of Python;
i.e. leave out generators, new-style class, list comprehensions, ability
to override built-in types, functions, and operators, and most of the
standard library, then you /might/ be able to fit a language with Pythonic
syntax in that address space.



I think to expand language by own library for Python - eg. control GPIO of
eZ80, read


Another issue would be speed. Z80s, though they''ve gotten faster over the
years, still only run at speeds on the order of 10MHz. You might be better
off writing a Z80 compiler for a Python-esque language -- this would save
both speed and memory.



speed 50MHz (or 20MHz in F92, F93...)


If you can pick a different chip, go with something like a StrongARM.
These have the power and address space necessary for Python. Plus, it''s
been done before (Python runs beautifully on modern PDAs).



I have just bought the developer kit for eZ80 so I have limited way. I''d be
happy to run Python on eZ80 platform.

thx
Janusz U.

If you stick with the Z80 though, you''ve got quite a challenge ahead of
you - good luck! If you succeed, you''ll be sure to make hackers of Game
Boys, TI-83s, and TRS-80s everywhere deliriously happy.



这篇关于z80 vs Python的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆