@@ -775,6 +775,42 @@ gpio!(GPIOG, gpiog, PGx, 'G', 6,
775775 PG15 : ( pg15, 15 , Analog , H8 , exticr4) ,
776776] ) ;
777777
778+ #[ cfg( any(
779+ // feature = "stm32l471", // missing PAC support for Port H
780+ feature = "stm32l475" ,
781+ feature = "stm32l476" ,
782+ feature = "stm32l485" ,
783+ feature = "stm32l486" ,
784+ feature = "stm32l496" ,
785+ feature = "stm32l4a6" ,
786+ // feature = "stm32l4p5",
787+ // feature = "stm32l4q5",
788+ // feature = "stm32l4r5",
789+ // feature = "stm32l4s5",
790+ // feature = "stm32l4r7",
791+ // feature = "stm32l4s7",
792+ feature = "stm32l4r9" ,
793+ feature = "stm32l4s9" ,
794+ ) ) ]
795+ gpio ! ( GPIOH , gpioh, PHx , 'H' , 7 , [
796+ PH0 : ( ph0, 0 , Analog , L8 , exticr1) ,
797+ PH1 : ( ph1, 1 , Analog , L8 , exticr1) ,
798+ PH2 : ( ph2, 2 , Analog , L8 , exticr1) ,
799+ PH3 : ( ph3, 3 , Analog , L8 , exticr1) ,
800+ PH4 : ( ph4, 4 , Analog , L8 , exticr2) ,
801+ PH5 : ( ph5, 5 , Analog , L8 , exticr2) ,
802+ PH6 : ( ph6, 6 , Analog , L8 , exticr2) ,
803+ PH7 : ( ph7, 7 , Analog , L8 , exticr2) ,
804+ PH8 : ( ph8, 8 , Analog , H8 , exticr3) ,
805+ PH9 : ( ph9, 9 , Analog , H8 , exticr3) ,
806+ PH10 : ( ph10, 10 , Analog , H8 , exticr3) ,
807+ PH11 : ( ph11, 11 , Analog , H8 , exticr3) ,
808+ PH12 : ( ph12, 12 , Analog , H8 , exticr4) ,
809+ PH13 : ( ph13, 13 , Analog , H8 , exticr4) ,
810+ PH14 : ( ph14, 14 , Analog , H8 , exticr4) ,
811+ PH15 : ( ph15, 15 , Analog , H8 , exticr4) ,
812+ ] ) ;
813+
778814struct Gpio < const P : char > ;
779815impl < const P : char > Gpio < P > {
780816 const fn ptr ( ) -> * const crate :: pac:: gpioa:: RegisterBlock {
@@ -820,7 +856,25 @@ impl<const P: char> Gpio<P> {
820856 feature = "stm32l4s9" ,
821857 ) ) ]
822858 'G' => crate :: pac:: GPIOG :: ptr ( ) as _ ,
823- _ => crate :: pac:: GPIOA :: ptr ( ) ,
859+ #[ cfg( any(
860+ // feature = "stm32l471", // missing PAC support for Port G
861+ feature = "stm32l475" ,
862+ feature = "stm32l476" ,
863+ feature = "stm32l485" ,
864+ feature = "stm32l486" ,
865+ feature = "stm32l496" ,
866+ feature = "stm32l4a6" ,
867+ // feature = "stm32l4p5",
868+ // feature = "stm32l4q5",
869+ // feature = "stm32l4r5",
870+ // feature = "stm32l4s5",
871+ // feature = "stm32l4r7",
872+ // feature = "stm32l4s7",
873+ feature = "stm32l4r9" ,
874+ feature = "stm32l4s9" ,
875+ ) ) ]
876+ 'H' => crate :: pac:: GPIOH :: ptr ( ) as _ ,
877+ _ => core:: ptr:: null ( ) ,
824878 }
825879 }
826880}
0 commit comments