RbgZ,2C © :e_dkZg^jLhjj_kOZjvdh\ (
[email protected] AKA 2:461/28) IhfZl_jbZeZfnbjfuNbebik RbgZ,2&rbjhdhbkihevam_lky\[ulh\hcwe_dljhgbd_i_j_^Zq_^Zgguo b ijhfure_gghc we_dljhgbd_ JZajZ[hlZggZy nbjfhc 3KLOLSV ijhklZy^\mgZijZ\e_ggZyijh\h^gZyrbgZ^eywnn_dlb\gh]hmijZ\e_gby b\aZbfh^_ckl\byjZaebqguo[ehdh\l_e_\bahjh\hgZklZeZijbf_gylvky ^ey k\yab f_`^m kh[hc h^ghdjbklZevguo fbdjhdhgljhee_jh\ @DB bg^bdZlhjh\ ihjlh\ \\h^Z\u\h^Z fbdjhko_f iZfylb hkh[_ggh wg_j]hg_aZ\bkbfhc ZgZeh]hpbnjh\uo b pbnjhZgZeh]h\uo ij_h[jZah\Zl_eyop_iyopbnjh\hcgZkljhcdb'70)dh^_jh\b^_dh^_jh\qZkh\j_Zevgh]h\j_f_gbbl^ <gZklhys__\j_fyZkkhjlbf_glfbdjhko_fkrbghc,2&lhevdhh^ghc nbjfu 3KLOLSV khklZ\ey_l [hevr_ q_f DFHI b [biheyjguo ijb[hjh\ Z \ h[eZklb wg_j]hg_aZ\bkbfhc iZfylb kj_^g_c _fdhklb hl khl_g [Zcl ^h ^_kyldh\ dbeh[Zcl hgZ klZeZ klZg^Zjlhf ^_nZdlh k_jbb ;;;nbjf0LFURFKLS$WPHOb^j RbgZ ,2& ij_^klZ\ey_l kh[hc dhgp_ipbx dhlhjZy j_rZ_l fgh]b_ ijh[e_fu bgl_jn_ckZ k dhlhjufb klZedb\Zxlky ijb ijh_dlbjh\Zgbb jZaebqghcZiiZjZlmjubbf__lke_^mxsb_^hklhbgkl\Z • Lhevdh^\_ebgbbihke_^h\Zl_evgZyebgby^Zgguo6'$ bihke_^h\Zl_evgZyebgbykbgojhgbaZpbb6&/ • DZ`^uc we_f_gl kh_^bg_gguc k rbghc y\ey_lky ijh]jZffgh Z^j_km_fufk\hbfmgbdZevgufZ^j_khfIjbwlhfhlghr_gbyf_`^m gbfbfh]ml[ulvihkljh_guihijhklhfmijbgpbimPDVWHUVODYHbeb`_ fh`_l[ulvihkljh_gZPXOWLPDVWHUkbkl_fZ • Wlh gZklhysZy rbgZ k \hafh`ghklvx jZ[hlu \ PXOWLPDVWHU kj_^_ \dexqZyijh\_jdmgZi_j_k_q_gb_bZj[bljZ` • Ihke_^h\Zl_evgZy jZajy^gZy ^\mgZijZ\e_ggZy i_j_^ZqZ ^Zgguo fh`_l ijh\h^blvky kh kdhjhklvx hl ^h NELWV \ klZg^Zjlghf j_`bf_beb^hNELWV\[ukljhfj_`bf_g_^ey\k_olbih\fbdjhko_f Ijb j_ZebaZpbb kh[kl\_gguo mkljhckl\ \hafh`gh ijbf_g_gb_ b[he__\ukhdbokdhjhkl_cijbkhojZg_gbbb^_heh]bbrbgu,2C. • NbevljZpby kb]gZeh\ \gmljb fbdjhko_f h[_ki_qb\Z_l g_qm\kl\bl_evghklvd\u[jhkZfgZebgbbrbgu^Zgguo • Qbkehmkljhckl\dhlhju_fh]ml[ulvkh_^bg_gu h^ghc rbghc h]jZgbq_ghlhevdhfZdkbfZevghc_fdhklvxrbguS)
2 Jbk^\Zijbf_jZijbf_g_gbyrbgu, C.
2
< ^hiheg_gb_ dh \k_f ij_bfms_kl\Zf fbdjhko_fu k rbghc , & \ DFHI bkiheg_gbb y\eyxlky hkh[_ggh ijb\e_dZl_evgufb ^ey i_j_ghkgh]hh[hjm^h\ZgbybkZ\Zjbcguf[ZlZj_cgufiblZgb_fhkh[_ggh\khq_lZgbb k gbadh ihlj_[eyxsbfb kbkl_fZfb mijZ\e_gby gZijbf_j gZ [Za_fbdjhdhgljhee_jh\nbjfu0LFURFKLSldfgh]b_bogbobf_xl • qj_a\uqZcghgbadh_ihlj_[e_gb_we_dljhwg_j]bb • \ukhdmxihf_ohmklhcqb\hklv • rbjhdbc^bZiZahgiblZxs_]hgZijy`_gby • rbjhdbcjZ[hqbc^bZiZahgl_fi_jZlmju >eyijhba\h^bl_e_cfbdjhko_frbgZ,2&ijb\e_dZl_evgZl_fqlh • ijhklhc ijh\h^ghc ihke_^h\Zl_evguc bgl_jn_ck fbgbfbabjm_l kh_^bg_gbyqlhmf_gvrZ_ldhebq_kl\h\u\h^h\ • iheghklvx bgl_]jbjh\Zgguc ,2& ijhlhdhe rbgu mkljZgy_l ihlj_[ghklv\^_dh^_jZoZ^j_kZbli • \hafh`ghklv ^bklZgpbhggh]h dhgljhey b gZkljhcdb q_j_a \g_rgb_ kh_^bg_gbygZdhfivxl_j_k[hjhqgh]hdhg\_c_jZ • \hafh`ghklv bkiheg_gby \ ex[hf lbi_ dhjimkZ 62 VPDOO RXWOLQH 962YHU\VPDOORXWOLQH ',/GXDOLQOLQH qlhmf_gvrZ_lfZkkmb]Z[Zjblu
ACCESS.BUS >jm]hc ijb\e_dZl_evghc klhjhghc rbgu ,2& ^ey ijh_dlbjh\sbdh\ b ba]hlh\bl_e_c y\ey_lky lh qlh ijhklhc ijh\h^ghc bgl_jn_ck b \hafh`ghklv ijh]jZffghc Z^j_kZpbb wlh b^_ZevgZy ieZlnhjfZ ^ey $&&(66%86Jbkmghd Wlh[he__^_r_\ZyZevl_jgZlb\Zbgl_jn_ckm 56& ^ey i_jbn_jbcguo mkljhckl\ dhfivxl_jh\ q_j_a ijhklhc dhglZdlguc kh_^bgbl_ev \dexqZxsbc ebgbb ,2& b ^\_ ebgbb iblZgby \b\
Jbk$&&(66EXVg_^hjh]ZyZevl_jgZlb\Z56
<>?GB?<KI?PBNBD:PBX,2C • • • •
H[uqgh^eyfgh]boijb[hjh\\u^\b]Zxlkyke_^mxsb_djbl_jbb ihegZy kbkl_fZ h[uqgh khklhbl ih djZcg_c f_j_ ba h^gh]h fbdjhdhgljhee_jZbi_jbn_jbcguomkljhckl\lbiZ[ehdh\iZfylbbjZkrbjbl_e_c\\h^Z\u\h^Z klhbfhklv kh_^bg_gby jZaebqguo we_f_glh\ \gmljb kbkl_fu ^he`gZ [ulvfbgbfZevghc kbkl_fZ dhlhjZy \uihegy_l lhevdh nmgdpbb mijZ\e_gby dZd ijZ\behg_lj_[m_l[ukljh^_ckl\mxs_ci_j_^Zqb^Zgguo h[sZy wnn_dlb\ghklv aZ\bkbl hl \u[jZgguo we_f_glh\ b oZjZdl_jZ f_`kh_^bg_gbc
Ihke_^h\Zl_evgZykljmdlmjZrbgum^h\e_l\hjy_lwlbfmkeh\byfOhlyihke_^h\Zl_evgu_rbgug_bf_xllZdhcijhba\h^bl_evghklbdZdiZjZee_evgu_rbguhgblj_[mxlf_gvr_]hdhebq_kl\Zijh\h^h\bf_gvr_]hdhebq_kl\Z\u\h^h\fbdjhko_fu We_f_glu h[sZxsb_ky ^jm] k ^jm]hf ih ihke_^h\Zl_evghc rbg_ ^he`gu bf_lv g_dhlhjuc ijhlhdhe dhlhjuc hij_^_ey_l eh]bdm nmgdpbhgbjh\Zgbyba[_]Z_l\k_o\hafh`ghkl_c[_kihjy^dZihl_jv^Zgguob [ehdbjh\Zgby bgnhjfZpbb ijb wlhf [uklju_ we_f_glu ^he`gu [ulv kihkh[guk\yaZlvkykf_^e_ggufbwe_f_glZfb
DHGP?IPBYRBGU 2
L?JFBGHEH=BYRBGU,2C I_j_^Zlqbdwe_f_gldhlhjucihkueZ_l^Zggu_\rbgm Ijb_fgbdwe_f_gldhlhjucihemqZ_l^Zggu_barbgu Master we_f_gl dhlhjuc bgbpbZebabjm_l i_j_^Zqm ]_g_jbjm_l kb]gZeukbgojhgbaZpbbbaZ\_jrZ_li_j_^Zqm Slaveih^qbg_gguc we_f_glZ^j_kh\ZggucfZkl_jhf Multi-masterkbkl_fZk[he__q_fh^gbffZkl_jhf :j[bljZ` ijhp_^mjZ ]ZjZglbjmxsZy qlh _keb [hevr_ q_f h^bg fZkl_jh^gh\j_f_gghijh[mxlmijZ\eylvrbghclhevdhh^bgbagboihemqblihegh_mijZ\e_gb_rbghcbh[_ki_qbli_j_^Zqm^Zgguo[_ahrb[hd KbgojhgbaZpbykbgojhgbaZpbyi_j_^Zqb^Zgguof_`^mwe_f_glZfb
2
JbkmghdIjbf_jdhgnb]mjZpbbrbgu, &bkihevamxs_c^\Zfbdjhdhgljhee_jZ
H;SB?O:J:DL?JBKLBDB 6'$ b 6&/ ^\mgZijZ\e_ggu_ ebgbb k hldjuluf klhdhf dhee_dlhjhf kh_^bg_ggu_kiheh`bl_evgufiblZxsbfgZijy`_gb_fq_j_aj_abklhjkfJbkmghd Dh]^ZrbgZk\h[h^gZh[_ebgbbgZoh^ylky\khklhygbb ³´ >Zggu_ fh]ml i_j_^Z\Zlvky ih rbg_ ,2& kh kdhjhklvx ^h NELWV \ klZg^Zjlghf j_`bf_ beb ^h NELWV \ [ukljhf j_`bf_ Qbkeh bgl_jn_ckh\ kh_^bg_gguo k rbghc bkdexqbl_evgh aZ\bkbl hl _fdhklbrbgufZdkbfZevgh_agZq_gb_dhlhjhcS)
JbkmghdKh_^bg_gb_,2&mkljhckl\
I?J?>:Q:;BL: BaaZ jZaghh[jZaby jZaebqguo l_ogheh]bc &026 1026 [biheyjgu_ijb[hju dhlhju_fh]ml[ulvbkihevah\Zgukrbghc,2&mjh\gbeh]bq_kdh]h³´b³´g_mklZgh\e_gubaZ\bkylhl\_ebqbguiblZxs_]hgZijy`_gby 9'' >ey i_j_^Zqb h^gh]h [blZ ^Zgguo bkihevam_lky h^bg bfimevkkb]gZeZkbgojhgbaZpbbijbwlhfmjh\_gvgZebgbb6'$^he`_g [ulvg_baf_gguf\l_q_gb_\ukhdh]hmjh\gygZebgbb6&/bfh`_lbaf_gylvky lhevdh ijb gbadhf mjh\g_ gZ 6&/ Jbkmghd Bkdexq_gbyfb kem`Zl^\Zhkh[uokhklhygby67$57b6723
JbkmghdI_j_^ZqZ[blZ 67$57b6723 2 Kms_kl\mxl ^\Z hkh[uo khklhygby rbgu , & VWDUW b VWRS dhlhju_ kem`Zl^eybg^bdZpbbgZqZeZbdhgpZi_j_^Zqbbkhhl\_lkl\_gghi_j_oh^Z rbgu \ g_Zdlb\gh_ khklhygb_ Ke_^m_l hlf_lblv qlh ^h l_o ihj ihdZg_mklZgh\e_ghkhklhygb_VWDUWkb]gZeugZebgbyo6'$b6&/fh]ml [ulv kh\_jr_ggh ijhba\hevgufb Jbkmghd Wlh iha\hey_l \ qZklghklb bkihevah\Zlv h^gm ebgbx 6'$ b g_kdhevdh ebgbc 6/& gZijbf_j ijbg_o\Zld_Z^j_kh\gZh^ghcrbg_ Khklhygb_67$57i_j_oh^hl³´d³´gZebgbb6'$ijb³´gZebgbb6&/
Khklhygb_6723i_j_oh^hl³´d³´gZebgbb6'$ijb³´gZebgbb6&/ Wlb^\Zkhklhygby\k_]^Z]_g_jbjmxlkyfZkl_jhf >_l_dlbjh\Zgb_khklhygbcVWDUWbVWRS\ki_pbZebabjh\Zgguowe_f_glZo h[uqgh ijhba\h^blky ZiiZjZlgh Ijb iheghklvx ijh]jZffghc j_ZebaZpbb rbgu ,2& \ fbdjhdhgljhee_jZo [_a ZiiZjZlghc ,2&qZklb g_h[oh^bfhdZdfbgbfmfjZaZijh\_jylvkhklhygb_ebgbb6'$
Jbkmghd67$57b6723khklhygby
I?J?>:Q:>:GGUO
Zggu_ i_j_^ZxlkygZqbgZykhklZjr_]h[blZ06% Jbkmghd ?kebijb_fgbdg_fh`_lihemqZlv^jm]hciheguc[Zcl^Zgguohgg_ \u^Z_l kb]gZe $&. dhlhjuc bkihevam_lky i_j_^Zlqbdhf ^ey kbgojhgbaZpbb beb kb]gZebaZpbb h g_bkijZ\ghklb ijb_fgbdZ beb _]h hlkmlkl\bb
JbkmghdI_j_^ZqZ^Zgguoihrbg_,2C.
ACKNOWLEDGE >eyih^l\_j`^_gbyi_j_^Zqb[ZclZi_j_^ZlqbdmklZgZ\eb\Z_lebgbx 6'$ \ ³´ \ l_q_gb_ kbgojhgbabjmxs_]h bfimevkZ Ijb_fgbd ijb wlhf ^he`_g\uklZ\blv³´gZ6'$jbkmghd ?kl_kl\_gghijbwlhf^he`gu [blv\u^_j`Zguhij_^_e_ggu_\j_f_ggu_khhlghr_gby H[uqgh ijb_fgbd dhlhjuc [ue Z^j_kh\Zg ^he`_g ]_g_jbjh\Zlv kb]gZe $&. ihke_ lh]h dZd dZ`^uc [Zcl [ue ihemq_g aZ bkdexq_gb_f lh]hdh]^Zkhh[s_gb_gZqbgZ_lkykZ^j_khf&%86 Dh]^Z ih^qbg_gguc ijb_fgbd g_ ih^l\_j`^Z_l ih^qbg_gguc Z^j_k gZijbf_j mkljhckl\h g_ ]hlh\h ihlhfm qlh wlh \uihegy_l g_dhlhjmx \gmlj_ggxxnmgdpbx ebgby6'$^Zgguo^he`gZ[ulvhklZ\e_gZ\³´ FZkl_jaZl_ffh`_l\u^Zlvkhklhygb_6723qlh[uij_j\Zlvi_j_^Zqm ?keb ih^qbg_gguc ijb_fgbd ih^l\_j`^Z_l ih^qbg_gguc Z^j_k gh g_dhlhjh_ \j_fy iha^g__ g_ fh`_l ihemqZlv [hevr_ [Zclu ^Zgguo fZkl_j^he`_gijbhklZgh\blvi_j_^Zqm Ijb ijb_f_ ihke_^g_]h [ZclZ \ k_jbb \f_klh kb]gZeZ $&. fZkl_j fh`_l \uklZ\blv khklhygb_ 6723 ijb wlhf ih^qbg_gguc i_j_^Zlqbd ^he`_ghk\h[h^blvebgbx^Zgguo
JbkmghdIh^l\_j`^_gb_i_j_^Zqb
:J;BLJ:@BKBGJHGBA:PBY KbgojhgbaZpby DZ`^h_ fZkl_jmkljhckl\h ]_g_jbjm_l kh[kl\_ggu_ kb]gZeu kbgojhgbaZpbbgZebgbb6&/>Zggu_gZebgbb6'$^_ckl\bl_evgulhevdhl_q_gb_
JbkmghdKbgojhgbaZpby\l_q_gb_ijhp_^mjuZj[bljZ`Z :j[bljZ` FZkl_j fh`_l gZqbgZlv i_j_^Zqm lhevdh _keb rbgZ k\h[h^gZ >\Z beb [hevr_ fZkl_jZ fh]ml ]_g_jbjh\Zlv khklhygb_ 67$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Zclihke_khklhygby67$57 Dh]^Z Z^j_k ihkeZg dZ`^uc we_f_gl \ kbkl_f_ kjZ\gb\Z_l i_j\u_ k_fv [blh\ ihke_ khklhygby 67$57 k kh[kl\_gguf Z^j_khf ?keb hgb kh]eZkmxlwe_f_glkqblZ_lk_[yZ^j_kh\ZgguffZkl_jhfdZdih^qbg_ggucijb_fgbdbebih^qbg_gguci_j_^Zlqbd\aZ\bkbfhklbhl5:[blZ Ih^qbg_gguc Z^j_k khklhbl ba ihklhygghc b i_j_f_gghc qZklb LZd dZd\_jhylghqlh[m^mlbf_lvkyg_kdhevdhb^_glbqguowe_f_glh\\kbkl_f_ lh ihklhyggZy qZklv m gbo [m^_l h^bgZdh\hc ld [m^_l y\eylvky dh^hfmkljhckl\Zi_j_f_ggZy`_ijbwlhf[m^_lh^ghagZqghb^_glbnbpbjh\Zlv dhgdj_lgh_ mkljhckl\h GZijbf_j gZ rbg_ ijbkmlkl\mxl mkljhckl\ihke_^h\Zl_evghcwg_j]hg_aZ\bkbfhciZfylb\k_hgbbf_xl h^bgZdh\ucdh^mkljhckl\ZklZjrb_[blZ ijbwlhffeZ^rb_[blZ [m^ml hij_^_eylv dZdh_ bf_ggh mkljhckl\h Z^j_km_lky \ ^Zgguc fhf_gl
G_dhlhju_ dh^u mkljhckl\ b Z^j_kZ aZj_a_j\bjh\Zgu ^ey hij_^_e_gguop_e_c SLAVE ADDRESS Dh^mkljhckl\Z :^j_k 0000 000 0000 000 0000 001 0000 010 0000 0000 1111 1111
011 1XX 1XX 0XX
5:[bl
HibkZgb_
0 1 X X
H[sbcZ^j_k START byte CBUS address AZj_a_j\bjh\Zgh ^ey ^jm]bo nhjfZlh\rbgu AZj_a_j\bjh\ZghgZ[m^ms__
X X X X
[blgZyZ^j_kZpby
H[sbcZ^j_k Hgkem`bl^eyZ^j_kZpbbex[h]hwe_f_glZgZrbg_H^gZdh_kebdZdhclhwe_f_glg_gm`^Z_lky\^hihegbl_evguo^Zgguohgfh`_lb]ghjbjh\Zlv wlhl Z^j_k g_ \u^Z\Zy d\blbjh\Zgb_ ?keb we_f_gl lj_[m_l ^Zgguoh[s_]hZ^j_kZhgih^l\_j^blwlhlZ^j_kb[m^_l\_klbk_[ydZd ih^qbg_gguc ijb_fgbd
JbkmghdNhjfZlh[s_]h\uah\Z Bf_xlky^\ZkemqZy Dh]^Z[bl%³´b\lhjhc[Zclbf__lke_^mxs__agZq_gb_ • + ZiiZjZlguck[jhk • + aZibkvi_j_f_gghcqZklbZ^j_kZ • + Wlhldh^g_^he`_gbkihevah\ZlvkydZd\lhjhc[Zcl Dh]^Z [bl % ³´ [Zclh\Zy ihke_^h\Zl_evghklv ³KDUGZDUH JHQHUDO call”. Wlh hagZqZ_l qlh ihke_^h\Zl_evghklv i_j_^ZgZ fZkl_jhf lbiZ deZ\bZlmjudhlhjucg_fh`_lijh]jZffbjh\Zlvkyqlh[ui_j_^Zlvgm`guc ih^qbg_ggucZ^j_kLZddZdfZkl_jg_agZ_laZjZg__ddZdhfmwe_f_glm khh[s_gb_ ^he`gh [ulv i_j_^Zgh lh hg fh`_l lhevdh ]_g_jbjh\Zlv
h[sbc\uah\bkh[kl\_ggucZ^j_k²b^_glbnbdZpby\kbkl_f_jbkmghd 17). K_fv [blh\ hklZxsb_ky \h \lhjhf [Zcl_ kh^_j`Zl Z^j_k fZkl_jZ Wlhl Z^j_k ^he`_g [ulv jZkihagZg ^jm]bf we_f_glhf gZijbf_j fbdjhdhgljhee_jhf kh_^bg_ggufkrbghc
JbkmghdI_j_^ZqZ^ZgguobafZkl_jZijbh[s_f\uah\_
START BYTE Fbdjhdhgljhee_ju fh]ml [ulv kh_^bg_gu k rbghc ,2& ^\mfy kihkh[Zfb 1. Fbdjhdhgljhee_j kh \kljh_gguf ZiiZjZlguf ,2&bgl_jn_ckhf fh`_l[ulvaZijh]jZffbjh\ZggZij_ju\Zgb_aZijhkZfbrbgu 2. G_ bf_xsbc lZdh]h bgl_jn_ckZ ^he`_g ihklhyggh dhgljhebjh\Zlvrbgmijh]jZffgh Hq_\b^gh \h \lhjhf kemqZ_ dhgljhee_j ^he`_g [hevr__ \j_fy hl\e_dZlvky gZ fhgblhjbjh\Zgb_ rbgu b f_gvr_ \j_f_gb aZgbfZlvky ^jm]bfbh[yaZgghklyfb < wlhf kemqZ_ i_j_^Zq_ ^Zgguo fh`_l ij_^r_kl\h\Zlv [he__ ^ebl_evgZyklZjlh\Zyijhp_^mjZjbkmghd Ijhp_^mjZkhklhblba • khklhygby67$576 • START BYTE (00000001) • ih^l\_j`^Zxs_]hkbgojhgbabjmxs_]hbfimevkZ$&. • ih\lhj_ggh]hkhklhygby67$576U Ihke_ lh]h dZd khklhygb_ 67$57 i_j_^Zgh fZkl_jhf i_j_^Z_lky klZjlh\uc[Zcl Fbdjhdhgljhee_j fh`_l ke_^h\Zl_evgh hijZrb\Zlv ebgbx 6'$ k gbadhc qZklhlhc ihdZ h^bg ba k_fb ghe_c \ klZjlh\hf [Zcl_ g_ [m^_l h[gZjm`_g Ihke_ h[gZjm`_gby wlh]h gmey gZ ebgbb 6'$ fbdjhdhgljhee_jfh`_li_j_dexqblvkygZ[he__\ukhdmxqZklhlm^bkdj_lbaZpbb qlh[ugZclbih\lhj_ggh_khklhygb_67$576U
Jbkmghd67$57%<7(
IH>DEXQ?GB?MKLJHCKL<KJ:AGUFBIBL:GBYFB JZaebqgu_ mkljhckl\Z fh]ml bkihevah\Zlv jZagu_ iblZxsb_ gZijy`_gby b mjh\gb kb]gZeh\ Ijb wlhf we_f_glu k nbdkbjh\Zggufb \oh^gufbmjh\gyfb9b9fh]mlbf_lvjZaebqgu_bklhqgbdbiblZgbyb ih^ly]b\Zxsb_j_abklhjuih^dexq_ggucdbklhqgbdm9jbkmghd We_f_gluk\oh^gufbmjh\gyfbaZ\bkysbfbhlgZijy`_gbyiblZgby ^he`gu bf_lv h[s__ iblZgb_ d dhlhjhfm ih^dexq_gu ih^ly]b\Zxsb_ j_abklhjujbkmghd ?keb we_f_glu k nbdkbjh\Zggufb \oh^gufb mjh\gyfb kf_rZgu k we_f_glZfb k \oh^gufb mjh\gyfb aZ\bkysbfb hl 9 '' g_h[oh^bfh \uihegylvkh_^bg_gbydZdihdZaZghgZjbkmgd_
JbkmghdWe_f_gluknbdkbjh\Zggufb\oh^gufbmjh\gyfb
JbkmghdWe_f_glukrbjhdbf^bZiZahghfiblZxs_]hgZijy`_gby
JbkmghdWe_f_gluk\oh^gufbmjh\gyfbk\yaZggufbk9''kf_rZggu_kwe_f_glZfbknbdkbjh\Zggufb\oh^gufbmjh\gyfb >eyaZsbluhl\ukhdh\hevlguoihf_o fh]ml ijbf_gylvky ihke_^h\Zl_evgu_j_abklhjujbkmghd
Jbkmghd>h[Z\hqgu_j_abklhju^eyaZsbluijhlb\\ukhdh\hevlguo \u[jhkh\
J:KRBJ?GB?RBGU,2C 2
e_lki_pbnbdZpbyrbgu, &hklZ\ZeZkvg_baf_gghckhkdhjhklvx i_j_^Zqb^Zgguo^hNELWVbjZajy^ghcZ^j_kZpb_cWlh[uehijbgylh \h \k_f fbj_ dZd nZdlbq_kdbc klZg^Zjl b khlgb jZaebqguo lbih\ I2&kh\f_klbfuo fbdjhko_f \uimkdZxlky nbjfhc 3KLOLSV b ^jm]bfb < 2 gZklhys__\j_fyki_pbnbdZpbyrbgu, &jZkrbj_gZ • [ukljuc j_`bf dhlhjuc iha\hey_l q_luj_odjZlgh_ m\_ebq_gb_ kdhjhklbi_j_^ZqbbgnhjfZpbb^hNELWV • jZajy^gZy Z^j_kZpby dhlhjZy iha\hey_l bkihevah\Zgb_ ^h ^hihegbl_evguoZ^j_kh\ 2
jZajy^gZy:>J?K:PBY Ijbbkihevah\ZgbbjZajy^ghcZ^j_kZpbbbkihevam_lkydh^mkljhckl\Z;;;^eyi_j\uok_fb[bli_j\h]h[ZclZdhlhjucg_\ha^_ckl\m_l gZ we_f_glu k h[uqghc jZajy^ghc Z^j_kZpb_c ihwlhfm we_f_glukjZajy^gufbbjZajy^gufbZ^j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oh^bfh \k_]h h^bg fZehfhsguc ljZgabklhj b iZjZ j_abklhjh\ Jbkmghd >Zgguc ijbf_j ij_^gZagZq_g ^ey jZ[hlu k ihke_^h\Zl_evghc wg_j]hg_aZ\bkbfhc iZfylvx gh ijb g_agZqbl_evghc fh^bnbdZpbb ijh]jZffuihegucbkoh^gucl_dkldhlhjhcgZLmj[hIZkdZe_ijb\_^_ggb`_ >ZggZyko_fZbijh]jZffZ>fbljb_fHjeh\ufby\eyxlkyIUHHZDUH program I2C_LPT; { Copyright Dmitry Orlov, 2:461/27 } uses CRT; var LPT1: Word; A: Word; Mode: (mError, mRead, mWrite); FileName: String[80]; Buf : Array[0..2047] of byte; F: File; procedure Pause; assembler; asm push ax @@0: jmp @@1 @@1: in al, dx pop ax end; procedure Start; assembler; asm mov dx, lpt1 mov al, 00000110b {Vcc = 1, SCL = 1, SDA = 1} out dx, al call Pause mov al, 00000111b {Vcc = 1, SCL = 1, SDA = 0} out dx, al call Pause mov al, 00000011b {Vcc = 1, SCL = 0, SDA = 0} out dx, al call Pause end; procedure Stop; assembler; asm mov dx, lpt1 mov al, 00000111b {Vcc = 1, SCL = 1, SDA = 0} out dx, al call Pause mov al, 00000110b {Vcc = 1, SCL = 1, SDA = 1} out dx, al call Pause end; function PutByte(B: Byte): boolean; assembler; asm mov dx, lpt1
mov ah, B mov cx, 8 @@0: rcl ah,1 jc @@1 mov al, 00000011b { Vcc = 1, SCL = 0, SDA = 0 } out dx, al call Pause mov al, 00000111b { Vcc = 1, SCL = 1, SDA = 0 } out dx, al call Pause mov al, 00000011b { Vcc = 1, SCL = 0, SDA = 0 } out dx, al jmp @@2 @@1: mov al, 00000010b out dx, al call Pause mov al, 00000110b out dx, al call Pause mov al, 00000010b out dx, al @@2: loop @@0 call Pause mov al, 00000110b out dx, al call Pause inc dx in al, dx dec dx and al, 01000000b mov ah, 1 je @@3 mov ah, 0 @@3: mov al, 00000010b out dx, al mov al, ah end;
{ Vcc = 1, SCL = 0, SDA = 1 } { Vcc = 1, SCL = 1, SDA = 1 } { Vcc = 1, SCL = 0, SDA = 1 }
{ Vcc = 1, SCL = 1, SDA = 1 }
{ Vcc = 1, SCL = 0, SDA = 1 }
function GetByte: byte; asm mov dx, lpt1 mov cx, 8 @@0: mov al, 00000110b { Vcc out dx, al call Pause inc dx in al, dx dec dx and al, 01000000b shl al,1 shl al,1 rcl ah, 1 mov al, 00000010b { Vcc out dx, al call Pause loop @@0 mov al, 00000110b { Vcc out dx, al call Pause
assembler;
= 1, SCL = 1, SDA = 1 }
= 1, SCL = 0, SDA = 1 }
= 1, SCL = 1, SDA = 1 }
mov al, 00000010b { Vcc = 1, SCL = 0, SDA = 1 } out dx, al call Pause mov al, ah end; procedure WriteByte(Addr:Word; B : Byte); begin Start; PutByte($A0 or ((Hi(Addr) shl 1) and $0e)); PutByte(Lo(Addr)); PutByte(B); Stop; Delay(5); end; function ReadByte(Addr:Word): Byte; begin Start; PutByte($A0 or ((Hi(Addr) shl 1) and $0e)); PutByte(Lo(Addr)); Start; PutByte($A1 or ((Hi(Addr) shl 1) and $0e)); ReadByte := GetByte; Stop; end; procedure ComStr; var PCStr : ^String; i: Byte; begin PCStr := Ptr(PrefixSeg, $80); for i := 0 to length(PCStr^) -1 do if PCStr^[i] in ['-', '/'] then begin case PCStr^[i+1] of 'r', 'R' : Mode := mRead; 'w', 'W' : Mode := mWrite; else Mode := mError; end; Delete(PCStr^, i, 2); Break; end; if ParamCount = 0 then Mode := mError else FileName := ParamStr(1); end; begin LPT1 := asm mov dx, mov al, out dx, end;
$378; lpt1 00000110b al
{ Vcc = 1}
ComStr; Assign(F, FileName); case Mode of mRead: begin for A:= 0 to 2047 do Buf[A] := ReadByte(A); Rewrite(F, 1);
if IOResult = 0 then begin BlockWrite(F, Buf, SizeOf(Buf)); Close(F); end; end; mWrite: begin Reset(F, 1); if IOResult = 0 then begin BlockRead(F, Buf, SizeOf(Buf)); Close(F); for A:= 0 to 2047 do WriteByte(A, Buf[A]); end; end; mError: begin WriteLn('24c16 fileName -r|-w'); WriteLn(' -r Read'); WriteLn(' -w Write'); end; end; end.
2
JbkmghdIh^dexq_gb_, &mkljhckl\Zd/37ihjlm JZamf__lky \ ^Zgghc klZlv_ g_\hafh`gh hibkZlv iheghklvx \k_ gx2 Zgkunmgdpbhgbjh\Zgbyrbgu, &ghihdjZcg_cf_j_fh`ghihemqblv h g_c h[s__ ij_^klZ\e_gb_ >ey [he__ ihegh]h bamq_gby fh`gh ihkh\_lh\Zlv • \bgl_jg_l_ 2 2 • hibkZgbywe_f_glh\krbghc &gZijbf_j^ZlZrblu, &((3520k_jbb;;;
nbjfu
fbdjhko_fnbjfu3KLOLSVb^jm]b_
OZjvdh\